Propagation mechanism for a non-preemptive strictly periodic scheduling problem
نویسندگان
چکیده
We study a non-preemptive strictly periodic scheduling problem. This problem, introduced in [6, 4], arises for example in the avionic field where a set of N periodic tasks (measure of a sensor, etc.) has to be scheduled on P processors distributed on the plane. In the related field of cyclic scheduling [5], some notable success [3] has been recently achieved through the use of specific constraint propagation. In this article, we consider a heuristic, first proposed in [1, 2], which is based on the notion of equilibrium. Following a game theory analogy, each task tries successively to optimize its own schedule and therefore to produce the best response, given the other schedules. We present a propagation mechanism for non-overlapping constraints which significantly improves this heuristic. 1 Periodic scheduling problem and its MILP formulation We consider a non-preemptive strictly periodic scheduling problem introduced in [6, 4, 1, 2]. Such a problem arises in the avionic field, where a set of N periodic tasks (measure of a sensor, etc.) has to be scheduled on P processors distributed on the plane. In this problem, each task i has a fixed period Ti and a processing time pi. They are subject to non-overlapping constraints : no two tasks assigned to the same processor can overlap during any time period (see Figure 1). A solution is given by an assignment of the tasks to the processors and, for each task by the start time ti (offset) of one of its occurrences. In the following, unlike the papers mentioned above, we adopt a more general model in which processing times pi are generalized by positive latency delays li,j ≥ 0 (or time lags). The former case is the particular case where li,j = pi for all other tasks j. The proposed heuristic adapts easily to this generalization. In this paper, we only consider the case where the offsets ti are integers. This hypothesis is important to prove convergence of the method described in section 2.1. Since the problem is periodic, all the periods Ti also need to be integers. • This work was funded by the French Midi-Pyrenee region (allocation de recherche post-doctorant n◦11050523) and the LAAS-CNRS OSEC project (Scheduling in Critical Embedded Systems). 1 Indeed, if ti is an integer solution then ti + Ti should also be an integer solution, hence their difference too, i.e. Ti. ha l-0 07 84 36 3, v er si on 1 4 Fe b 20 13 However the latency delays need not be integer a priori, especially in the case of the optimization problem presented in section 1.1. Fig. 1. N = 4 non-overlapping periodic tasks on P = 1 processor 1.1 Definition of the uniprocessor problem Non-overlapping constraints In the formulation of a monoprocessor periodic scheduling problem, a latency delay li,j ≥ 0 has to be respected whenever an occurrence of a task j starts after an occurrence of a task i. Said differently, the smallest positive difference between two such occurrences has to be greater than li,j . Using Bézout identity, the set (tj+TjZ)−(ti+TiZ) of all the possible differences is equal to (tj − ti) + gi,jZ where gi,j = gcd(Ti, Tj). The smallest positive representative of this set is (tj − ti) mod gi,j . This is the only representative of (tj − ti) + gi,jZ which belongs to [0, gi,j − 1] (in particular, we consider a classic positive modulo, and not a signed modulo). Therefore, we simply consider the following constraint : (tj − ti) mod gi,j ≥ li,j , ∀(i, j), i 6= j (1) Classically, processing times are strictly positive, however our model allows zero delays. Since equation (1) is trivially satisfied when li,j = 0, we introduce an additional graph G containing the arcs (i, j) for which li,j > 0, and we consider equation (1) only for those couples. As we will see, the constraints associated with (i, j) and (j, i) work naturally together and some complications are introduced when only one of the couples has a strictly positive delay. To avoid special cases, we will suppose in the following that the graph G is symetric : two delays li,j and lj,i are either both zero, or both strictly positive. With this hypothesis, a consequence of proposition 1 (see Appendix) is that equation (1) can be replaced by the following interval constraint for each couple (i, j) ∈ G with i < j : li,j ≤ (tj − ti) mod gi,j ≤ gi,j − lj,i, ∀(i, j) ∈ G, i < j (2) Note that except for the modulo, these constraints have a clear analogy with classical precedence constraints of the form tj−ti ≥ li,j . However, they are much harder to handle since they induce an exclusion between tasks. 2 Note that this hypothesis can always be enforced. If li,j > 0, then the tasks i and j are constrained not to start at the same time. Hence the same is true for the tasks j and i. Therefore, lj,i can also be supposed strictly positive. 3 In particular, a classic disjunctive constraint tj − ti ≥ li,j ∨ ti − tj ≥ li,j can be represented by the two constraints (tj − ti) mod T ≥ li,j and (ti − tj) mod T ≥ lj,i for a large enough period T . ha l-0 07 84 36 3, v er si on 1 4 Fe b 20 13 Objective to maximize In an uncertain context, a task may last longer than expected, due to failure of the processor. This increase in the duration is naturally proportional to the original processing time. To withstand the worst possible slowdown, it is natural to make all the delays li,j proportional to a common factor α ≥ 0 that we try to optimize (see [1, 2]). max α (3) s.t. li,jα ≤ (tj − ti) mod gi,j ≤ gi,j − lj,iα ∀(i, j) ∈ G, i < j (4) ti ∈ Z ∀i (5) α ≥ 0 (6) The addition of this objective is also a good way to obtain feasible solutions. In the context of precedence constraints, a way to implement the Bellman-Ford algorithm is to cyclically choose a task and to push it forward, up to the first feasible offset. In section 2.2 we present a method to find the next feasible offset in the case of non-overlapping constraints. However there isn’t necessarily a solution and a similar propagation mechanism which would cyclically move one task at a time to the first feasible location would have only a small chance to converge towards a feasible solution. However, with the optimization problem, there is always at least a solution having a zero α-value. We can then try to inflate α, while moving a task, what we call the best-response method : instead of choosing the first feasible location, we search for the best location with respect to this additional objective α. Whenever a solution with α ≥ 1 is found, we have a solution for the feasibility problem. This is essentially the principle of the heuristic presented in section 2. Structure of the solution set An optimal solution is completely defined by the offsets, since given the offsets (ti) we can always compute the best compatible α-value : α = min (i,j)∈G (tj − ti) mod gi,j li,j (7) If we try to draw the function α = (ti − tj) mod gi,j/lj,i representing the optimal value of α respecting one constraint (ti − tj) mod gi,j ≥ lj,iα when ti takes rational values, we obtain a curve which is piecewise increasing and discontinuous since it becomes zero on tj + gi,jZ. In the same way, if we draw α = (tj − ti) mod gi,j/li,j , we obtain a curve which is piecewise decreasing and becomes zero at the same points. It is therefore more natural to consider the two constraints jointly, i.e. (4), which gives a continuous curve (see Figure 2) . Since G is symetric, it can be seen as an undirected graph. We will write G(i) for the set of neighbors of i, i.e. the set of tasks with which i is linked through non-overlapping constraints. With this notation, and given some fixed 4 Note that if G was not symetric, we would need to consider some degenerate cases were one of the slope (increasing or decreasing) would be infinite (since li,j = 0 or lj,i = 0). ha l-0 07 84 36 3, v er si on 1 4 Fe b 20 13 Fig. 2. Possible values for (ti, α) when constrained by a single task j offsets (tj)j∈G(i), the set of solutions (ti, α) is the intersection of the curves decribed above for each j ∈ G(i) (see Figure 3). It is composed of several adjacent polyhedra. We can give an upper bound on the number npoly of such polyhedra. A polyhedron starts and ends at zero points. For a given constraint j, there is Ti/gi,j zero points in [0, Ti − 1], hence npoly is bounded by Ti ∑ j 6=i 1 gi,j . This upper bound can be reached when the offsets are fractional, since in this case, we can always choose the offsets tj such that the sets of zero points (tj+gi,jZ)j∈G(i) are all disjoint. In the case of integer offsets, there is obvioulsy at most Ti zero points in the interval [0, Ti − 1] and therefore, at most Ti polyhedra. Fig. 3. Possible values for (ti, α) constrained by all tasks j ∈ G(i) We obtain the shape of a two dimensional slice of the solution set, for a given task i, and some fixed (tj)j∈G(i). We will see how these two-dimensional slices help to understand the concept of equilibrium and the heuristic : when solving the best-response method, we try to find the new location ti which maximize the α-value. Following the same idea, the complete full dimensional solution set is composed of several adjacent N + 1-dimensional polyhedra. 1.2 MILP formulation of the multiprocessor problem MILP formulation In this section, we present a MILP formulation of the problem which will be used to compare the performance of our heuristic. As explained above, the modulo (tj−ti) mod gi,j is the only element tj−ti+gi,jqi,j in the interval [0, gi,j). Here, qi,j is an additional ‘quotient variable’ which can always be computed by : qi,j = d(ti − tj)/gi,je (8) Hence for a given couple (i, j) ∈ G, with i < j, the non-overlapping constraint (4) can be rewritten as li,jα ≤ tj−ti+gi,jqi,j ≤ gi,j−lj,iα. In the multiprocessor case, the scheduling problem is coupled with an assignment problem. Thus, we introduce binary variables ai,k which indicate if a task i is assigned to a processor ha l-0 07 84 36 3, v er si on 1 4 Fe b 20 13 k, and variables xi,j which indicate if i and j are on different processors. These variables must satisfy (10) and (11). Since the non-overlapping constraints have to be satisfied whenever two tasks are on the same processor, we replace the term li,jα by li,jα− li,jαmaxxi,j . When i and j are on the same processor (xi,j = 0), we find back the original term li,jα, otherwise we obtain a negative term li,jα− li,jαmax which makes the constraint trivially satisfiable. This yields constraints (12) and (13).
منابع مشابه
An Optimization via Simulation approach for the preemptive and non-preemptive multi-mode resource-constrained project scheduling problems
In this paper a novel modelling and solving method has been developed to address the so-called resource constrained project scheduling problem (RCPSP) where project tasks have multiple modes and also the preemption of activities are allowed. To solve this NP-hard problem, a new general optimization via simulation (OvS) approach has been developed which is the main contribution of the current re...
متن کاملLine search method for solving a non-preemptive strictly periodic scheduling problem
We study a non-preemptive strictly periodic scheduling problem. This problem arises for example in the avionic field where a set of N periodic tasks (measure of a sensor, data presentation, etc.) has to be scheduled on P processors distributed on the plane. In this article, we consider an existing heuristic which is based on the notion of equilibrium. Following a game theory analogy, each task ...
متن کاملModeling and Solution Procedure for a Preemptive Multi-Objective Multi-Mode Project Scheduling Model in Resource Investment Problems
In this paper, a preemptive multi-objective multi-mode project scheduling model for resource investment problem is proposed. The first objective function is to minimize the completion time of project (makespan);the second objective function is to minimize the cost of using renewable resources. Non-renewable resources are also considered as parameters in this model. The preemption of activities ...
متن کاملSchedulability Analysis for non Necessarily Harmonic Real-Time Systems with Precedence and Strict Periodicity Constraints using the Exact Number of Preemptions and no Idle Time
Scheduling theory as it applies to hard real-time environments with precedence and strict periodicity constraints — environments where the failure to satisfy any constraint may have disastrous consequences [1], [2] — seems currently to be enjoying a renaissance. The most widely studied problems in this field concern periodic non-preemptive tasks for systems where data are collected throught cap...
متن کاملSingle-machine Scheduling with Periodic Maintenance and both Preemptive and Non-preemptive jobs in Remanufacturing System
This paper considers a single-machine scheduling with preventive periodic maintenance activities in remanufacturing system. Although the scheduling problem with maintenance has attracted researchers’ attention, most of past studies consider only non-preemptive jobs. In fact, there exist both preemptive and non-preemptive jobs due to their different processing technic in remanufacturing workshop...
متن کاملOptimizing a bi-objective preemptive multi-mode resource constrained project scheduling problem: NSGA-II and MOICA algorithms
The aim of a multi-mode resource-constrained project scheduling problem (MRCPSP) is to assign resource(s) with the restricted capacity to an execution mode of activities by considering relationship constraints, to achieve pre-determined objective(s). These goals vary with managers or decision makers of any organization who should determine suitable objective(s) considering organization strategi...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 2013